package org.example;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import java.util.ArrayList;
import java.util.List;
import java.util.UUID;

@SpringBootApplication
public class App implements CommandLineRunner {
    public static void main(String[] args) {
        SpringApplication.run(App.class, args);
    }

    @Autowired
    private UserService userService;

    @Autowired
    private BloomFilterService bloomFilterService;

    @Override
    public void run(String... args) throws Exception {
//        List<User> list = userService.load();
//        System.out.println(list.size());
//        list.stream().forEach(item -> {
//            bloomFilterService.add(item.getVin());
//        });
//        System.out.println(bloomFilterService.ct());
    }
}

/*
CREATE TABLE `user` (
  `id` int NOT NULL AUTO_INCREMENT,
  `name` varchar(100) DEFAULT NULL,
  `vin` varchar(32) DEFAULT NULL,
  `type` char(1) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1376223 DEFAULT CHARSET=utf8mb3;
 */